﻿using System;
using System.Collections.Generic;

using System.Text;
using Estimate.Common.DBFieldTypes;

namespace Estimate.Common.Entity
{
    /// <summary>
    /// Fore类型表的记录值
    /// </summary>
    [Serializable]
    public class ForeEntity : ICloneable
    {
        public int Id { get; set; }
        public DateTime Date { get; set; }
        public ForeClockType Clock { get; set; }
        public ForeSpanType Span { get; set; }
        public ForeFactorType Type { get; set; }
        public ForeSemiType Semitype {  get; set; }
        public ForeSendpointType Sendpoint { get; set; }
        public string Value { get; set; }
        public string Semi { get; set; }
        public List<string> semis = new List<string>();

        public ForeEntity()
        { }

        public ForeEntity(DateTime date, ForeClockType clock, ForeSpanType span, ForeFactorType type, ForeSemiType semitype,ForeSendpointType sendpoint)
        {
            Date = date;
            Clock = clock;
            Span = span;
            this.Type = type;
            Semitype = semitype;
            Sendpoint = sendpoint;
            Semi = "";
            Value = "";
        }

        public ForeEntity(DateTime date, ForeClockType clock, ForeSpanType span, ForeFactorType type, ForeSemiType semitype, ForeSendpointType sendpoint, string value):
            this(date,clock,span,type,semitype,sendpoint)
        {
            Value = value;
        }

        public ForeEntity(DateTime date, ForeClockType clock, ForeSpanType span, ForeFactorType type, ForeSemiType semitype, ForeSendpointType sendpoint, string value, string semi) :
            this(date, clock, span, type, semitype, sendpoint)
        {
            Value = value;
            Semi = semi;
        }

        public object Clone()
        {
            return new ForeEntity(Date, Clock, Span, Type, Semitype, Sendpoint, Value, Semi);
        }

    }
}
